<?php

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
 if ( !is_user_logged_in() ){
	wp_redirect(home_url('anh-cuoi/dang-nhap')); 
 }
 global $wpdb; 
 
 $user_ID = get_current_user_id();

 $exist_choose_1 = $wpdb->get_row("SELECT * FROM gallery_selected_img WHERE user_id = {$user_ID} AND type = 1");
 $exist_choose_2 = $wpdb->get_row("SELECT * FROM gallery_selected_img WHERE user_id = {$user_ID} AND type = 1 AND status = 1 ");

 
?>
<div class="anhcuoi_menu" >
<div class="breadcrumbs">
	<?php if(function_exists('bcn_display'))
	{
		bcn_display();
	}?>
</div>

<div class="anhcuoi menu">
	<div class="userinfo">Ảnh cưới anh chị Nam Mai - Ngày cưới 25.09.3013</div>
    <ul>
        <li class="<?php echo is_page('huong-dan-su-dung') ? 'active' : ''  ?>" ><a href="<?php echo home_url('huong-dan-su-dung') ?>">Hướng dẫn sử dụng</a></li>
        <li class="<?php echo is_page('hinh-goc') ? 'active' : ''  ?>" ><a href="<?php echo home_url( 'hinh-goc') ?>">Hình gốc</a></li>
		<li class="<?php echo is_page('chon-hinh') ? 'active' : ''  ?>" ><a href="<?php echo home_url( 'chon-hinh') ?>">Chọn hình</a></li>
		<?php if(isset($exist_choose_1->id )) { ?>
        <li class="<?php echo is_page('chon-hinh-lan-1') ? 'active' : ''  ?>" ><a href="<?php echo home_url( 'chon-hinh-lan-1') ?>">HÌNH ĐÃ CHỌN</a></li>
		<?php } ?>
		<?php if(isset($exist_choose_2->id ) && $exist_choose_1->status == 1 ) { ?>
        <li class="<?php echo is_page('chon-hinh-lan-2') ? 'active' : ''  ?>" ><a href="<?php echo home_url( 'chon-hinh-lan-2') ?>">DUYỆT HÌNH ALBUM</a></li>
		<?php } ?>
        <li class="<?php echo is_page('album-cuoi') ? 'active' : ''  ?>" ><a href="<?php echo home_url('album-cuoi') ?>">Album cưới</a></li>
		        <li class="<?php echo is_page('hinh-le') ? 'active' : ''  ?>" ><a href="<?php echo home_url('hinh-le') ?>">Hình lẻ</a></li>

        <li class="<?php echo is_page('hinh-tiec') ? 'active' : ''  ?>" ><a href="<?php echo home_url('hinh-tiec') ?>">Hình tiệc</a></li>
        <li class="<?php echo is_page('video') && $_GET['type'] == 1 ? 'active' : '' ?>"><a href="<?php echo home_url( 'anh-cuoi/video/?type=1') ?>">Đĩa chiếu</a></li>
        <li class="<?php echo is_page('video') && $_GET['type'] == 2 ? 'active' : '' ?>" ><a href="<?php echo home_url( 'anh-cuoi/video/?type=2') ?>">Phim cưới</a></li>
        
    </ul>
</div>
</div>